1. Field of the Invention
The invention relates generally to Serial Attached SCSI (SAS) expanders and more specifically relates to implementation of Fast Context Switching (FCS) capability for Serial Advanced Technology Attachment (SATA) target devices and SATA Tunneling Protocol (STP) initiators coupled with FCS enhanced SAS expanders.
2. Discussion of Related Art
In a SAS environment, one or more SAS initiator devices are coupled with one or more SAS and/or SATA target devices through zero or more intermediate SAS expanders. In general, the collection of SAS expanders (that provide switchable connections between the various initiator and target devices) is referred to as a SAS Service Delivery Subsystem (SDS). SAS standards also provide for coupling SATA target devices to such an SDS utilizing the STP. STP enables an STP initiator to establish a connection through the SDS to a SATA target device coupled to the SDS.
In accordance with present SAS specifications, an open connection is initially established by a SAS initiator transmitting an Open Address Frame (OAF) through the SDS and receiving an acceptance (OPEN_ACCEPT primitive) from the identified SAS target device. The open request and acceptance are routed and passed through each SAS expander between the initiator and target. Once such a connection is established, all PHYs used for the connection by SAS expanders intermediate the initiator and target devices are essentially in a “pass-through” mode until the connection is closed by the initiator device (e.g., DONE primitives and CLOSE primitives are exchanged between the SAS end devices to thereby close the established connection). Once an expander senses that a previously established connection has been closed, it may again enter its state machine logic to await receipt of a next OAF to establish another connection. Similarly, in accordance with STP, connections are initially established by the STP initiator transmitting an OAF to an identified SATA target device. The SAS expander that is directly coupled with the identified SATA target device (the “end expander”) responds with an OPEN_ACCEPT on behalf of the identified SATA device to thus establish the desired connection through the SDS. The STP initiator may similarly determine when the connection is no longer required and exchange appropriate DONE and CLOSE primitives with the end expander to close the established STP connection.
In initially establishing such a requested connection, SAS expanders intermediate the initiator and target devices acquire various resources within the expander to identify the requested connection and identify appropriate routing through PHYs of the expanders to establish and utilize the connection. When the SAS expander detects closure of a previously established connection, resources previously acquired for that connection are released for reuse to establish other connections within the expander.
In some recent developments, one vendor has proposed enhancements or extensions to the SAS protocols to allow multiple connections between a single initiator and multiple SAS target devices to remain open or established such that switching between connections may be performed by a faster switch operation rather than “tearing down” all resources by closing an established connection and re-opening another connection. For example, LSI Corporation proposes enhancements or extensions to the SAS protocols referred to as Fast Context Switching (FCS). An FCS enhanced SAS expander that is directly coupled to multiple SAS target devices is enhanced to maintain multiple established, open connections and to detect receipt of a new form of SAS frame that requests a fast context switch from the currently utilized, previously established connection to a another presently open, previously established connection. Thus, multiple established connections may remain open between a single SAS initiator and multiple SAS target devices and a new SAS frame (e.g., a SWITCH Address Frame—“SAF”) may be used to rapidly switch between previously established connections without incurring the overhead of “tearing down” and “setting up” each connection sequentially. In essence, the SAF is processed the same as an OAF if there is no presently established connection that may be re-used for the requested new connection. However, if another previously established connection may be re-used, the SAF processing avoids all the overhead processing of “tearing down” and “setting up” connections each time a new connection is requested.
A problem arises in such FCS enhanced SAS expanders in that SATA devices coupled with the SDS are not capable of participating in the FCS enhanced features. Thus, an initiator device cannot maintain multiple open/established connections that include a SATA target device.
It is therefore an ongoing challenge to provide mechanisms to utilize FCS enhancements to maintain open connections to SATA target device coupled with SDS.